<template>
    <div>
		<headerSearch :title="headTitle"></headerSearch>
    <!-- 下拉出现功能 -->
		<!-- <div class="dropDownpanel" v-if="dropintopShow">
            <span class="dropdown_triangle"></span>
            <a href="javascript:void(0)"><i class="iconfont icon-fenxiang4" ></i>分享名片</a>
            <a href="javascript:void(0)" @click="chengeTemplate"><i class="iconfont icon-mobanliebiao"></i>更换模板</a>
            <a href="javascript:void(0)"><i class="iconfont icon-genghuanyanse"></i>更换颜色</a>
        </div> -->
        <div class="content" style="background-color: #f5f5f5;">
            <!-- 头部名片浮层 -->

            <div class="main_card_index" v-if="CardDetails.CardTemplate == 1">
                <div class="main_card_index_info-top"></div>
                <div class="main_card_index_info">
                    <div class="main_card_index_info_top_edit clear">
                        <editorHead v-on:CardLogo="CardLogo" :CardLogo="CardDetails.CardLogo" v-if="desc_Show" class="editor_Card"></editorHead>
                        <img v-else :src="CardDetails.CardLogo" alt="">
                        <!-- <img v-else src="../common/images/cindex_37.jpg" alt=""> -->
                        <div class="main_card_index_info_center_edit">
                            <h2 v-if="desc_Show"><span class="company_description_span" contenteditable="true" ref="CardName">{{CardDetails.CardName}}</span> <span v-if="desc_Show" class="company_description_span" contenteditable="true" ref="CardPosition">{{CardDetails.CardPosition}}</span></h2>
                            <h2 v-else><span contenteditable="false">{{CardDetails.CardName}}</span> <span contenteditable="false">{{CardDetails.CardPosition}}</span></h2>
                            <p v-if="desc_Show && CardDetails.is_admin == 'yes'" class="company_description_span" contenteditable="true" ref="CardCompany">{{CardDetails.CardCompany}}</p>
                            <p v-else ref="CardCompany" contenteditable="false">{{CardDetails.CardCompany}}</p>
                        </div>
                        <div class="main_card_index_info_right" @click="editorPeopledesc(onlystau)">
                            <a><i class="iconfont icon-bianji1"></i>{{editortext_one}}</a>
                        </div>
                    </div>
                    <div class="main_card_index_info_bottom">
                        <p v-if="CardDetails.CardPhone">
                            <i class="iconfont icon-dianhua2"></i>
                            <a href="javascript:void(0)" v-if="desc_Show" class="company_description_info" contenteditable="true" ref="CardPhone">{{CardDetails.CardPhone}}</a>
                            <a :href="'tel:' + CardDetails.CardPhone" v-if="!desc_Show" contenteditable="false">{{CardDetails.CardPhone}}</a>
                            <!-- <a href="tel:15220666130" class="small_span_color" v-if="!desc_Show" disabled="disabled">立即通话</a> -->
                        </p>
                        <p>
                            <i class="iconfont icon-youxiang"></i>
                            <span class="company_description_info" v-if="desc_Show" contenteditable="true" ref="CardEmail">{{CardDetails.CardEmail}}</span>
                            <span v-if="!desc_Show" ref="CardEmail" contenteditable="false">{{CardDetails.CardEmail}}</span>
                        </p>
                        <p class="clear">
                            <i class="iconfont icon-dizhi1"></i>
                            <a href="javascript:void(0)" class="company_description_info" v-if="desc_Show" contenteditable="true" ref="CardCompanyAddress">{{CardDetails.CardCompanyAddress}}</a><button v-if="desc_Show" @click="MapPosition">定位当前定位</button>
                            <a href="javascript:void(0)" v-if="!desc_Show" contenteditable="false">{{CardDetails.CardCompanyAddress}}</a>
                            <!-- <a href="javascript:void(0)" class="small_span_color" v-if="!desc_Show" disabled="disabled">马上定位</a> -->
                            <!-- <i class="iconfont icon-erweima fr"></i> -->
                        </p>
                    </div>
                </div>
            </div>

            <div class="main_card_index" v-else>
                <div class="main_card_index_info-top"></div>
                <div class="main_card_index_info">
                    <div class="main_card_index_info_top clear">
                        <h6>我是待开发的模板2</h6>
                        <editorHead v-on:CardLogo="CardLogo" :CardLogo="CardDetails.CardLogo" v-if="desc_Show" class="editor_Card"></editorHead>
                        <img v-else :src="CardDetails.CardLogo" alt="">
                        <!-- <img v-else src="../common/images/cindex_37.jpg" alt=""> -->
                        <div class="main_card_index_info_center">
                            <h2 v-if="desc_Show"><span class="company_description_span" contenteditable="true" ref="CardName">{{CardDetails.CardName}}</span> <span v-if="desc_Show" class="company_description_span" contenteditable="true" ref="CardPosition">{{CardDetails.CardPosition}}</span></h2>
                            <h2 v-else><span contenteditable="false">{{CardDetails.CardName}}</span> <span contenteditable="false">{{CardDetails.CardPosition}}</span></h2>
                            <p v-if="desc_Show && CardDetails.is_admin == 'yes'" class="company_description_span" contenteditable="true" ref="CardCompany">{{CardDetails.CardCompany}}</p>
                            <p v-else ref="CardCompany" contenteditable="false">{{CardDetails.CardCompany}}</p>
                        </div>
                        <div class="main_card_index_info_right" @click="editorPeopledesc(onlystau)">
                            <a><i class="iconfont icon-bianji1"></i>{{editortext_one}}</a>
                        </div>
                    </div>
                    <div class="main_card_index_info_bottom">
                        <p>
                            <i class="iconfont icon-dianhua2"></i>
                            <a href="javascript:void(0)" v-if="desc_Show" class="company_description" contenteditable="true" ref="CardPhone">{{CardDetails.CardPhone}}</a>
                            <a :href="'tel:' + CardDetails.CardPhone" v-if="!desc_Show" contenteditable="false">{{CardDetails.CardPhone}}</a>
                            <!-- <a href="tel:15220666130" class="small_span_color" v-if="!desc_Show" disabled="disabled">立即通话</a> -->
                        </p>
                        <p>
                            <i class="iconfont icon-youxiang"></i>
                            <span class="company_description" v-if="desc_Show" contenteditable="true" ref="CardEmail">{{CardDetails.CardEmail}}</span>
                            <span v-if="!desc_Show" contenteditable="false">{{CardDetails.CardEmail}}</span>
                        </p>
                        <p class="clear">
                            <i class="iconfont icon-dizhi1"></i>
                            <a href="javascript:void(0)" class="company_description" v-if="desc_Show" contenteditable="true" ref="CardCompanyAddress">{{CardDetails.CardCompanyAddress}}</a><button v-if="desc_Show" @click="position">定位</button>
                            <a href="javascript:void(0)" v-if="!desc_Show" contenteditable="false">{{CardDetails.CardCompanyAddress}}</a>
                            <!-- <a href="javascript:void(0)" class="small_span_color" v-if="!desc_Show" disabled="disabled">马上定位</a> -->
                            <i class="iconfont icon-erweima fr"></i>
                        </p>
                    </div>
                </div>
            </div>
            

            <!-- 内容访问量 -->
            <div class="main_Headline_data" v-if="isShowTag">
                <small>访问量<em> {{CardDetails.access}} </em></small>
                <small>人气值<em> {{CardDetails.popularity}} </em></small>
                <small>分享数<em> {{CardDetails.share}} </em></small>
                <!-- <small class="data_jin">#IT互联网</small>
                <small class="data_jin">#诚信</small>
                <small class="data_jin">#大道至简</small> -->
				<div class="notice_editor" v-show="notice_editor">
					<!-- <i class="iconfont icon-shanjian" @click="cli_notice_editor"></i> -->
					<small>
						<a href="javascript:void(0)" @click="deleteCom('tag')"><i class="iconfont icon-shanchu"></i>删除</a>
						<!-- <a href="javascript:void(0)" @click="editordesc(stau)"><i class="iconfont icon-bianji1 icon_editor"></i>{{editortext}}</a> -->
					</small>
				</div>
            </div>
            <!--公司简介-->
            <div class="look_container">
                <div class="title_text_more" >
                    <h3>公司简介</h3>
                    <div style="line-height: 0.8rem;" v-show="com_set_show">
                        <!-- <a href="javascript:void(0)" style="font-size: 0.28rem !important;" @click="deleteCom(1)"><i class="iconfont icon-shanchu" style="font-size: 0.26rem;margin-right: 0.1rem;"></i>删除</a> -->
                        <a href="javascript:void(0)" style="font-size: 0.28rem !important;" @click="editordesc(stau)"><i class="iconfont icon-bianji1 icon_editor" style="font-size: 0.26rem;margin-right: 0.1rem;"></i>{{editortext}}</a>
                    </div>
                </div>  
                <div class="main-company-index-description">
                    <div class="option_description">
                        <div class="userCard_check_img">
                            <img :src="options.log_img" alt="" v-if="options.log_img">
                            <img src="../common/images/youquan.png" alt="" v-else>
                        </div>
                    
                        <div style="text-align: left;">
                            <h3>{{CardDetails.company.name}}</h3>
                            <p>{{CardDetails.company.website}}</p>
                            <!-- <p v-if="CardDetails.company.website == '' || CardDetails.company.website == null">暂无网站</p> -->

                        </div>
                    </div>
                    <div class="option_tagNames">
                        <span v-for="(biao, b) in tags" :key="b">{{biao.label_name}}</span>
                    </div>
                    <p v-if="descShow" class="company_description" contenteditable="true" ref="mybox">{{ CardDetails.CardCompanyDesc?CardDetails.CardCompanyDesc:'暂无简介' }}</p>
                    <p v-if="!descShow" ref="mybox" contenteditable="false">{{ CardDetails.CardCompanyDesc?CardDetails.CardCompanyDesc:'暂无简介' }}</p>
                </div>
                <a href="javascript:;" class="btn_more" @click="btn_more">查看企业&nbsp;<i class="iconfont icon-xiangyou"></i></a>
            </div>
            <!-- 产品列表 -->
            <div class="main-company-index_product look_container" v-if="isShowProduct">
                <div class="title_text_more">
                    <h3>产品列表</h3>
                    <div style="line-height: 0.8rem;">
                        <a href="javascript:void(0)" style="font-size: 0.28rem !important;" @click="deleteCom('product')"><i class="iconfont icon-shanchu" style="font-size: 0.26rem;margin-right: 0.1rem;"></i>删除</a>
                        <a href="javascript:void(0)" style="font-size: 0.28rem !important;" @click="activeditorClick('product_hot')"><i class="iconfont icon-bianji1 icon_editor" style="font-size: 0.26rem;margin-right: 0.1rem;"></i>编辑</a>
                    </div>
                    <!-- <a href="javascript:void(0)">
                        更多<i class="iconfont icon-xiangyou"></i>
                    </a>                -->
                </div>  
                <!-- 三栏商品 -->
                <div class="host_item" id="js_host_item">
                    <div class="emptyProduct" v-if="CardDetails.module.product.length == 0">
                        <img src="../common/images/empty.png" alt="">
                        <p>小主人，您的商品还没添加呢~请赶紧添加吧!</p>
                    </div>
                    <ul v-else>
                        <li v-for="(host, h) in CardDetails.module.product" :key="h" @click="jumpProduct(host.IDProduct)">
                            <a href="javascript:void(0)">
                                <img src="../common/images/cm_03.jpg" v-if="host.smallImg == null">
                                <img :src="host.smallImg" alt="" v-else>
                                
                                <!-- <span>{{host.chrName}}</span> -->
                                <span class="hui_title">{{host.chrName}}</span>
                                <!-- <span>已售<strong>{{host.NumS}}</strong>件</span> -->
                                <span>已售<strong>{{host.NumS}}</strong>件</span>
                            </a>
                        </li>
                    </ul>
                </div> 			
            </div>  
            <!-- 新闻动态 -->
            <div class="main-company-index_product look_container" v-if="isShowNews">
              <div class="title_text_more">
                <h3>新闻动态</h3>
                <div style="line-height: 0.8rem;">
                    <a href="javascript:void(0)" style="font-size: 0.28rem !important;" @click="deleteCom('news')"><i class="iconfont icon-shanchu" style="font-size: 0.26rem;margin-right: 0.1rem;"></i>删除</a>
                    <a href="javascript:void(0)" style="font-size: 0.28rem !important;" @click="activeditorClick('news')"><i class="iconfont icon-bianji1 icon_editor" style="font-size: 0.26rem;margin-right: 0.1rem;"></i>编辑</a>
                </div>
                <!-- <router-link to="/newsList">更多<i class="iconfont icon-xiangyou"></i></router-link> -->
              </div>
              <div class="info_list_home_page">
                <div class="emptyProduct" v-if="CardDetails.module.news.length == 0">
                    <img src="../common/images/empty.png" alt="">
                    <p>小主人，您的新闻还没添加呢~请赶紧添加吧!</p>
                </div>
                <ul v-else v-for="(initem, t) in CardDetails.module.news" :key="t" >
                  <li @click="newsdetailClick(initem.IDNews)" v-if="initem.img.length < 2">
                    <a href="javascipt:void(0)" class="clear">
                      <div class="new_info_single_img fl">
                        <img :src="initem.img" alt="" v-if="initem.img[0]"> 
                        <img src="../common/images/cindex_41.jpg" v-else>
                      </div>
                      <!-- <p>{{initem.Title}}</p> -->
                      <p>{{initem.Title}}</p>
                      <p><span>{{initem.chrFrom}}</span><span>{{initem.dtCreate | dateFormat("yyyy-MM-dd")}}</span></p>
                      <!-- <p><span>{{initem.summary}}</span><span>{{initem.dtCreate}}</span></p> -->
                    </a>
                  </li>
                  <li  @click="newsdetailClick(initem.IDNews)" v-else>
                    <div class="info_home_page">
                      <!-- <p>{{initem.Title}}</p> -->
                      <p>{{initem.Title}}</p>
                      <ul>
                        <!-- <li v-for="(info, fo) in initem.img" :key="fo"> -->
                        <li v-for="(img, i) in initem.img" :key="i">
                          <a href="javascript:void(0)">
                            <span class="new_info_img fl">
                                <img class="info_home_img" :src="img">
                            </span>
                            <!-- <img :src="path + info" alt="" v-else> -->
                          </a>
                        </li>
                      </ul>
                      <!-- <p class="info_time"><span>{{initem.summary}}</span><span>{{initem.dtCreate}}</span></p> -->
                      <p class="info_time"><span>{{initem.chrFrom}}</span><span>{{initem.dtCreate | dateFormat("yyyy-MM-dd")}}</span></p>
                    </div> 
                  </li>
                </ul>
              </div>
            </div>
            <!-- 添加模块 -->
            <div class="mycard_insert" v-show="add_module" @click="addModule">
                <i class="iconfont icon-icon02"></i>
                <span>添加模块</span>
			</div>
            <!-- 分享按钮 -->
            <!-- <div class="view_card_share" :style="'right: ' + position ">
              <div class="share_hide_btn" @click="showFunc"><i class="iconfont icon-fanhui"></i></div>
              <div class="share_hide_collection">
                <div class="hide_collection"><i class="iconfont icon-shoucang"></i><span>更换颜色</span></div>
                <div class="hide_collection" @click="chengeTemplate"><i class="iconfont icon-shoucang"></i><span>切换模板</span></div>-->
                <!-- <div class="hide_collection"><i class="iconfont icon-fenxiang2"></i><span>分享名片</span></div> -->
              <!-- </div>
            </div> -->
        </div>
		<!-- 编辑动态 -->
		<div class="Editorial_dynamics" v-show="activeShow">
			<div class="intop"></div>
			<div class="editorial_list">
				  <div class="editorial_title">
							<button @click="cancel">取消</button>
							<h3>{{Title}}({{xNum}}/{{cNum}})</h3>
							<button @click="finish(check)">完成</button>
					</div>
					<div class="editorial_content" style="height: 6.1rem;overflow-y: auto;">
						<div class="editorial_excl" v-for="(list, act) in edit_list" :key="act">
							<div class="editorial_item clear" style="position: relative;">
									<div class="fl " v-show="ed_show">
										<img :src="list.img" alt="">
									</div>
									<div class="editorial_item_title fl" :value="list.id">
										 <p v-if="list.name">{{list.name}}</p>
										 <p class="clear" v-show="ed_show">
                                            <span class="fl" v-show="Num_show">已售<em>{{list.Num}}</em>件</span>
                                            <span class="fr">{{list.date_time | dateFormat("yyyy-MM-dd")}}</span>
										 </p>
									</div>
									<div class="editorial_change fr">
										<!-- <Checkbox @checkClick="choose()"></Checkbox> -->
										 <Checkbox :model.sync="list.checked" @update:model="singChange()" :ref="'edit_id' + list.id" :disabled="list==='1'"></Checkbox>
									</div>
							</div>
						</div>
					</div>
					
			</div>
		</div>
        <so-footer></so-footer>
        <!-- 添加模块 -->
        <div class="addModuleList" v-if="isAddModule">
        <ul>
            <li v-for="(item, index) in addModuleList" :key="index">
            <div @click="addWhatModule(index)">{{item}}</div>
            </li>
            <li @click="cancelAddModule">取消</li>
        </ul>
        </div>
    </div>
</template>

<script>
import headerSearch from '../public/header-search.vue';
import soFooter from '../components/footer-bar';
import Checkbox from '../components/Checkbox';
import editorHead from '../public/editor_head';
import wx from 'weixin-js-sdk';


    export default {
        data() {
            return {
                // imgUrl: this.$path, // 域名
                access_token: '', // 令牌
                card_id: '', // 名片id
                CardDetails: '', // 存放进来的名片数据
                // QRcode: '../common/images/u3103.png', // 
                Card: { // 请求数据
                    access_token: '',
                    user_id: 0
                },
                prev_ids: '', // 用于存放上此点击的ids
                CardName: '', // 名片名
                CardCompany: '', // 名片公司
                CardPosition: '', // 名片职位
                CardEmail: '', // 名片邮箱
                CardPhone: '', // 名片电话
                CardCompanyAddress: '', // 名片企业地址
                CardCompanyDesc: '', // 名片企业简介
                isEditProduct: false, // 是否编辑产品
                isEditNews: false, // 是否编辑新闻
                productList: [], // 存放产品列表数据
                newsList: [], // 存放新闻列表数据
                isShowProduct: false, // 是否显示产品模块
                isShowNews: false, // 是否显示新闻模块
                isShowTag: false, // 是否显示变迁模块
                isAddModule: false, // 是否添加模块
                // addModuleList: [{id: 'tag', name: '标签模块'}, {id: 'product', name: '产品模块'}, {id: 'news', name: '新闻模块'}], // 存放添加模块列表
                addModuleList: {}, // 存放添加模块列表
                selectProduct: [], // 选中的产品
                selectNews: [], // 选中的新闻
                /*********************************** */
                headTitle: '名片编辑',
                options: '',   //企业名称
                notice_editor: true,  //访问量
                editortext: '编辑',  //简介编辑
                editortext_one: '编辑',  //头部个人信息编辑
                descShow: false, //简介编辑
                desc_Show: false, //个人信息编辑
                stau:1,
                onlystau: 1,
                type:'2',
                com_set_show:true,//公司简介模块显示控制
                classA:'main-company-index-Intro',
                notice_show:true,//公告显示
                notice_editor:true,//公告遮罩层显示控制
                activeShow: false, //活动编辑
                add_module:true,//添加模块显示控制
                Title:'产品动态',//编辑标题
				cNum:0,//需要显示的总是
                xNum:0,//
                edit_list:[],
                ed_show:false,
                Num_show:false,
                
                position: '-2.66rem', // 默认样式
                isCollect: false,
                tags: [],       //标签
                check: '',
                // dropintopShow: false, //遮罩层
            }
        },
        created() {
            let that = this;
            that.userInfo = JSON.parse(window.localStorage.getItem('userInfo'));
            that.Card.access_token = window.localStorage.getItem('access_token');
            that.Card.user_id = JSON.parse(window.localStorage.getItem('userInfo')).uid;
            that.card_id = that.$route.query.card_id;
            console.log(that.card_id);
            that.getcarddetail();
            // that.userInfo = JSON.parse(that.userInfo);
            //获取当前企业的详细内容
            // that.getCompanyInfo();
            // 动态加载百度地图
            if (!window.BMap) {
                var script = $('<script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=' + this.$baidu_map_ak + '"></sc' + 'ript>');
                var script2 = $('<script type="text/javascript" src="http://api.map.baidu.com/getscript?v=2.0&amp;ak=' + this.$baidu_map_ak + '&amp;services=&amp;t=20190123111209"></s' + 'cript>');
                $('body').append(script);
                $('body').append(script2);
            }

        },
        methods: {
            /**
             * 切换名片模板，暂时只支持2个版
             */
            chengeTemplate: function(){
                if(this.CardDetails.CardTemplate == 1){
                    this.CardDetails.CardTemplate = 2;
                }else{
                    this.CardDetails.CardTemplate = 1;
                }
                var data = this.Card;
                data.template = this.CardDetails.CardTemplate;
                this.$post(this.$path + '/index.php/api/selectTemplate/'+this.card_id, data).then((response) => {
                    this.tags = response.data;
                })
                // this.dropintopShow = false;
            },

            //定位浏览器判断
            MapPosition:function(){
                var ua = navigator.userAgent.toLowerCase();
            　　  var isWeixin = ua.indexOf('micromessenger') != -1;
            　　  if (isWeixin) {  //微信
                    console.log('微信浏览器的');
                    this.location();
            　　  }else{          //普通浏览器
                    console.log('普通浏览器的');
                    this.BaiDumap();
            　　  }
            },
            /**
             * 通过定位拿到当前地址，便于修改
             */
            location: function(){
                // alert('进来了微信');
                var that = this;
                // var url = location.href.split('#')[0];
                var u = navigator.userAgent;
                var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1; //g
                var isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端
                let url='';
                if (isAndroid) {
                    url=location.href;
                }
                if (isIOS) {
                    url=location.href.split('#')[0];  //hash后面的部分如果带上ios中config会不对
                }
                console.log('检测url',url);
                that.$post(that.$path + '/index.php/api/v2/getJsapiTicket', {url: url}).then((res) => {
                    console.log('微信res',res);
                    if(res.code == 200){
                        wx.config({
                            debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来，若要查看传入的参数，可以在pc端打开，参数信息会通过log打出，仅在pc端时才会打印。
                            appId: res.data.appid, // 必填，公众号的唯一标识
                            timestamp: res.data.timestamp, // 必填，生成签名的时间戳
                            nonceStr: res.data.noncestr, // 必填，生成签名的随机串
                            signature: res.data.signature,// 必填，签名
                            jsApiList: ['checkJsApi', 'openLocation', 'getLocation'] // 必填，需要使用的JS接口列表
                        });
                        wx.ready(function(){
                            wx.checkJsApi({
                                jsApiList: ['openLocation', 'getLocation'], // 需要检测的JS接口列表，所有JS接口列表见附录2,
                                success: function(res) {
                                    console.log(res)
                                    // alert(res);
                                    // 以键值对的形式返回，可用的api值true，不可用为false
                                    // 如：{"checkResult":{"chooseImage":true},"errMsg":"checkJsApi:ok"}
                                }
                            });
                            // 使用微信获取经纬度，在用百度地图的逆地址解析，解析出经纬度对应的地名
                            wx.getLocation({
                                type: 'wgs84', // 默认为wgs84的gps坐标，如果要返回直接给openLocation用的火星坐标，可传入'gcj02'
                                success: function (res) {
                                    var latitude = res.latitude; // 纬度，浮点数，范围为90 ~ -90
                                    var longitude = res.longitude; // 经度，浮点数，范围为180 ~ -180。
                                    // var pt = {lat: res.latitude, lng: res.longitude}
                                    // alert('经度：' + res.longitude);
                                    // alert('维度：' + res.latitude);
                                    var pt = new BMap.Point(res.longitude, res.latitude)
                                    // var pt = new BMap.Point(116.354969, 39.348339)
                                    var geoc = new BMap.Geocoder(); 
                                    geoc.getLocation(pt, function(rs){
                                        console.log(rs)
                                        that.CardDetails.CardCompanyAddress = rs.address;
                                    })
                                }
                            });
                            
                        });
                        wx.error(function(res){
                            // config信息验证失败会执行error函数，如签名过期导致验证失败，具体错误信息可以打开config的debug模式查看，也可以在返回的res参数中查看，对于SPA可以在这里更新签名。
                            console.log(res);
                        });
                    }
                })
            },
            BaiDumap:function()
            {   
                console.log('进来了百度地图');
                var that = this;
                // 百度地图API功能
                // var map = new BMap.Map("app");
                // var point = new BMap.Point(116.331398,39.897445);
                // map.centerAndZoom(point,12);
                // console.log(map);
                // console.log('point',point);
                var geolocation = new BMap.Geolocation();
                // console.log('geolocation',geolocation);
                geolocation.getCurrentPosition(function(r){
                    // console.log('r',r);
                    if(this.getStatus() == BMAP_STATUS_SUCCESS){
                        var mk = new BMap.Marker(r.point);
                        // console.log('mk',mk);
                        // map.addOverlay(mk);
                        // map.panTo(r.point);
                        // alert('您的位置：'+r.point.lng+','+r.point.lat);
                        // alert('您的位置:'+r.address.province + ',' + r.address.city);
                        var point = new BMap.Point(r.point.lng,r.point.lat);
                        var geoc = new BMap.Geocoder(); 
                        geoc.getLocation(point, function(rs){
                            console.log(rs)
                            that.CardDetails.CardCompanyAddress = rs.address;
                        })
                    }
                    else {
                        // alert('failed'+this.getStatus());
                    }        
                },{enableHighAccuracy: true})
                //关于状态码
                //BMAP_STATUS_SUCCESS   检索成功。对应数值“0”。
                //BMAP_STATUS_CITY_LIST 城市列表。对应数值“1”。
                //BMAP_STATUS_UNKNOWN_LOCATION  位置结果未知。对应数值“2”。
                //BMAP_STATUS_UNKNOWN_ROUTE 导航结果未知。对应数值“3”。
                //BMAP_STATUS_INVALID_KEY   非法密钥。对应数值“4”。
                //BMAP_STATUS_INVALID_REQUEST   非法请求。对应数值“5”。
                //BMAP_STATUS_PERMISSION_DENIED 没有权限。对应数值“6”。(自 1.1 新增)
                //BMAP_STATUS_SERVICE_UNAVAILABLE   服务不可用。对应数值“7”。(自 1.1 新增)
                //BMAP_STATUS_TIMEOUT   超时。对应数值“8”。(自 1.1 新增)
            },
             /**
              * 获取标签列表
              */
            getLabellist(c_id){
                let that = this;
                that.$fetch(that.$path + '/index.php/api/c/label/'+c_id).then((response) => {
                    that.tags = response.data;
                    console.log('获取标签列表',response);
                })
            },
            /**
             * 更换名片logo的回调
             */
            CardLogo: function(data){
                this.CardDetails.CardLogo = data;
            },
            addWhatModule: function(module) {
                var that = this;
                if (module == 'tag') {
                    this.isAddModule = false;
                    this.isShowTag = true;
                    delete this.addModuleList.tag;
                    var data = {
                        module: 'tag',
                        ids: ''
                    };
                    //请求接口修改产品热销状态
                    that.$post(that.$path + '/index.php/api/editCardModule/' + this.card_id, data).then((response) => {
                        if(response.code == 200) {
                            that.getcarddetail();
                        }
                    })
                }
                if (module == 'product') {
                    this.activeditorClick('product_hot');
                    this.isAddModule = false;
                }
                if (module == 'news') {
                    this.activeditorClick('news');
                    this.isAddModule = false;
                }
            },
            /**
             * 取消添加模块
             */
            cancelAddModule: function() {
                this.isAddModule = false;
            },
            addModule: function() {
                this.isAddModule = true;
            },
            /**
             * 获取名片详情
             */
            getcarddetail() {
                this.$post(this.$path + '/index.php/api/CardDetails/' + this.card_id, {user_id: this.Card.user_id}).then((response) => {
                // 初始化数据
                if (response.code == 200) {
                    this.CardDetails = response.data;
                    console.log('初始化数据', this.CardDetails)
                    // 如果没有企业
        
                    this.CardName = response.data.CardName;
                    this.CardCompany = response.data.CardCompany;
                    this.CardPosition = response.data.CardPosition;
                    this.CardEmail = response.data.CardEmail;
                    this.CardPhone = response.data.CardPhone;
                    this.CardCompanyAddress = response.data.CardCompanyAddress;
                    this.CardCompanyDesc = response.data.CardCompanyDesc;
                    // 是否显示模块
                    if (response.data.module.tag != '0') {
                        this.isShowTag = true;
                    } else {
                        this.isShowTag = false;
                        this.addModuleList.tag = '添加标签';
                    }
                    if (response.data.module.product != '0') {
                        this.isShowProduct = true;
                    } else {
                        this.isShowProduct = false;
                        this.addModuleList.product = '添加产品';
                    }
                    if (response.data.module.news != '0') {
                        this.isShowNews = true;
                    } else {
                        this.isShowNews = false;
                        this.addModuleList.news = '添加新闻';
                    }
                    response.data.module.product.forEach((element,index) => {
                        console.log(element);
                        this.selectProduct.splice(0,0,{id:element.IDProduct,name:element.chrName,img:element.smallImg,date_time:element.dtCreate,Num:element.NumS});
                    });
                    response.data.module.news.forEach((element,index) => {
                        console.log(element);
                        this.selectNews.splice(0,0,{id:element.IDNews,name:element.Title,img:element.img[0],date_time:element.dtCreate});
                    });

                    //新添加
                    // this.getLabellist(response.data.c_id);


                }
        
                })
                // console.log(Object.keys(this.addModuleList))
            },
            
            /**
             * 去查看企业
             */
            btn_more(){
                if(this.$system != 'ios'){
                    this.$router.push({
                            path: '/userCenter/companyIndex',
                            query: {cp_id: this.CardDetails.c_id}
                    })
                }else{
                    window.location.href = '/userCenter/companyIndex?cp_id=' + this.CardDetails.c_id;
                }       
            }, 
			/**
             * 点击编辑公司简介可编辑
             */
			editordesc(stau) {
				let that = this;
				if(stau == 1){//点击编辑
                    that.editortext = '保存';
                    that.stau =2;
				}else{//点击保存
				//更新公司简介
					let cpId = that.cp_id;
                    let desc = this.$refs.mybox.innerHTML; 
                    if (desc == '') {
                        this.$openTips({
                            text: '请输入公司简介',
                            time: 2000
                        })
                        return false;
                    }
                    var data = {
                        CardCompanyDesc: desc,
                        is_admin: this.CardDetails.is_admin,
                        c_id: this.CardDetails.c_id
                    };
                    this.$post(this.$path + '/index.php/api/editCardCompanyDesc/' + this.card_id, data).then((response) => {
                        if (response.code == 200) {
                            that.notice_show = false;
                            that.classA = 'main-company-index-Intro notice-n';
                            this.$openTips({
                            text: '编辑成功',
                            time: 2000
                            })
                        } else {
                            this.$openTips({
                            text: '系统繁忙，请稍后再试',
                            time: 2000
                            })
                        }
                
                    })
					// console.log(desc);return false;
					// that.$post(that.$path + '/api.php/company/editorCompanyDescription',{cpId:cpId,desc:desc}).then((response) => {
                    //         console.log('企业信息001',response);return false;
                    //         if(response.code == 200){
                    //         }
                        
                    // })
					that.editortext = '编辑';
                    that.stau =1;
                    that.contenteditable = 'false';
				}
				this.descShow = !this.descShow;
            },
            /**
             * 点击编辑头部个人信息
             */ 
            editorPeopledesc(onlystau) {
                let that = this;
				if(onlystau == 1){//点击编辑
                    that.editortext_one = '保存';
                    that.onlystau =2;
				}else{//点击保存
				//更新头部个人信息
					// let cpId = that.cp_id;
					let CardName = that.$refs.CardName.innerHTML; 
					let CardPosition = that.$refs.CardPosition.innerHTML; 
					let CardCompany = that.$refs.CardCompany.innerHTML; 
					let CardPhone = that.$refs.CardPhone.innerHTML; 
					let CardEmail = that.$refs.CardEmail.innerHTML; 
                    let CardCompanyAddress = that.$refs.CardCompanyAddress.innerHTML; 

                        if (CardName == '') {
                            that.$openTips({
                                text: '名片姓名不能为空',
                                time: 2000
                            })
                            return false;
                        }
                        //名片名
                        if (CardPosition == '') {
                            that.$openTips({
                                text: '工作职位不能为空',
                                time: 2000
                            })
                            return false;
                        }
                        // 手机
                        if (!(/^1[34578]\d{9}$/.test(CardPhone))) {
                            that.$openTips({
                                text: '手机格式错误，请重新填写',
                                time: 2000
                            })
                            return false;
                        }
                        // 邮箱
                        if(CardEmail == '') {
                            that.$openTips({
                                text: '邮箱不能为空',
                                time: 1000
                            })
                            return false;
                        }
                        // if (!(/^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,4})$/.test(CardEmail))) {
                        //     that.$openTips({
                        //         text: '邮箱格式错误，请重新填写',
                        //         time: 1000
                        //     })
                        //     return false;
                        // }
                        //名片名
                        if (CardCompanyAddress == '') {
                            that.$openTips({
                                text: '工作地点不能为空',
                                time: 1000
                            })
                            return false;
                        }
                    var data = {
                        user_id: that.Card.user_id,
                        CardName: CardName,
                        CardCompany: CardCompany,
                        CardPosition: CardPosition,
                        CardEmail: CardEmail,
                        CardPhone: CardPhone,
                        CardCompanyAddress: CardCompanyAddress,
                        c_id: that.CardDetails.c_id,
                        CardLogo: that.CardDetails.CardLogo
                    };
                    that.$post(that.$path + '/index.php/api/editCard/' + that.card_id, data).then((response) => {
                        if (response.code == 200) {
                            that.$openTips({
                                text: '编辑成功',
                                time: 2000
                            })
                            // that.getcarddetail();
                        } else {
                            that.$openTips({
                                text: '系统繁忙，请稍后再试',
                                time: 2000
                            })
                        }
                    })
					// console.log(desc);return false;
					// that.$post(that.$path + '/api.php/company/editorCompanyDescription',{cpId:cpId,desc:desc}).then((response) => {
                    //         console.log('企业信息001',response);return false;
                    //         if(response.code == 200){
                    //             that.notice_show = false;
                    //             that.classA = 'main-company-index-Intro notice-n';
                    //         }
                        
                    // })
					that.editortext_one = '编辑';
                    that.onlystau =1;
                    // that.contenteditable = 'false';
				}
				that.desc_Show = !that.desc_Show;
            },
			/**
             * 删除模块
             */
			deleteCom(type){
                var that = this;
                var data = {
                    module: type,
                    ids: 0
                };
                this.$post(this.$path + '/index.php/api/editCardModule/' + this.card_id, data).then((response) => {
                    if (response.code == 200) {
                        this.$openTips({
                            text: '修改成功',
                            time: 2000
                        })
                        // that.isShowProduct = false;
                        // this.isAddModule = true;
                        // that.addModuleList.product = '添加产品';
                        // this.addModuleList.push('product');
                        that.getcarddetail();
                    } else {
                        this.$openTips({
                            text: '系统繁忙，请稍后再试',
                            time: 2000
                        })
                    }
            
                })
				// console.log(type);
				// let that = this;
				// let cpId = that.options.cp_id;
				// let status = 2;
				// that.$post(that.$path + '/api.php/company/deleteCompanyModule',{cpId:cpId,status:status,module:type}).then((response) => {
				// 	console.log('企业信息',response);return false;
				// 	if(response.code == 200){
				// 		that.notice_show = false;
				// 		that.classA = 'main-company-index-Intro notice-n';
				// 	}
				
	            // })
                // switch(type){
                //     case 1 :
                //     that.com_show=false//公司简介显示控制
                //     break;
                //     case 2 :
                //         that.fa_show=false//法人代表模块显示控制
                //     break;
                //     case 3 :
                //         that.base_show=false//基本信息显示控制
                //     break;
                //     case 4 :
                //         that.hot_show=false//热销模块显示控制
                //     break;
                //     case 5 :
                //         that.qi_show=false//抢购模块显示控制
                //     break;
                //     case 6 :
                //         that.new_show=false//新闻咨询模块显示控制
                //     break;
                //     case 7 :
                //         that.hou_show=false//活动模块显示控制
                //     break;
                // }
			},
			/**
             * 点击商品查看详情
             */
			jumpProduct(val){
				console.log(val);
				this.$router.push({
						path: '/productDetail',
						query: {id: val}
				})
            },
            /**
             * 点击新闻详情
             */
            newsdetailClick(val) {
                this.$router.push({ path: '/newsDetail',query: {id: val}});
            },
            /**
             * 点击编辑广告
             */
			cli_notice_editor(){
				// console.log(999);
				let that = this;
				that.$post(that.$path + '/api.php/company/editorCompanyNotice',{n_id:that.options.c_id,status:2}).then((response) => {
					console.log('企业信息',response);
					if(response.code == 200){
						that.notice_show = false;
						that.classA = 'main-company-index-Intro notice-n';
					}
	            })
            },
			/**
             * 活动编辑
             */
			cancel() {
				this.activeShow = false;
			},
			/**
             * 点击完成
             */
			finish(val) {
				let that = this;
				let ids = that.ids;
				let c_id= that.cp_id;
				if(val == 'product_hot'){
					var data = {
                        module: 'product',
                        ids: ids ? ids.slice(0,-1) : ''
                    };
                    //请求接口修改产品热销状态
                    that.$post(that.$path + '/index.php/api/editCardModule/' + this.card_id, data).then((response) => {
                            if(response.code == 200) {
                                delete that.addModuleList.product;
                                that.getcarddetail();
                            }
                    })
				}else if(val == 'product_panic'){
					let type =2;
					//请求接口修改产品抢购状态
						that.$post(that.$path + '/index.php/api/updateProducstatus/'+c_id+'/'+ids+'/'+type).then((response) => {
								if(response.code == 200) {
										that.getCompanyInfo();
								}
						})
				}else if(val == 'news'){
					var data = {
                        module: 'news',
                        ids: ids ? ids.slice(0,-1) : ''
                    };
                    //请求接口修改产品热销状态
                    that.$post(that.$path + '/index.php/api/editCardModule/' + this.card_id, data).then((response) => {
                            if(response.code == 200) {
                                delete that.addModuleList.news;
                                that.getcarddetail();
                            }
                    })
				}else if(val == 'activity'){
					let type =2;
					//请求接口修改活动状态
						that.$post(that.$path + '/api.php/Activity/updateActivitystatus',{ids,c_id}).then((response) => {
								if(response.code == 200) {
										that.getCompanyInfo();
								}
						})
                }
                // else if(val == 'module'){
                //     ids = ids.slice(0,-1).split(',');
                //     console.log(ids);
                    
				// 	// let status =1;
				// 	//请求接口修改模块状态
				// 		// that.$post(that.$path + '/api.php/Company/updateCompanyModule',{c_id,ids,status}).then((response) => {
				// 		// 		if(response.code == 200) {
				// 		// 				that.getCompanyInfo();
				// 		// 		}
				// 		// })
				// }
				
				this.activeShow = false;

			},
			/**
             * 点击编辑
             */
			activeditorClick(val) {
                console.log(val);
				let that = this;
				let c_id = that.cp_id;
				if(val == 'product_hot'){//获取当前企业热销产品
					that.Num_show = true;
					// that.cNum = 3;
                    that.Title='热销产品';
                    that.ed_show=true;
                    var data = this.Card;
                    data.c_id = this.CardDetails.c_id;
                    // this.$post(this.$path + '/index.php/api/productList', data).then((response) => {
                    // console.log(response);
                    // if(response.code == 200){
                    // that.edit_list = response.data;
                    // for (let i = 0; i < that.CardDetails.module.product.length; i++) {
                    //     setTimeout(() => {
                    //         $('#p' + that.CardDetails.module.product[i].IDProduct)[0].checked = true;
                    //     }, 10);
            
                    // }
					that.$post(that.$path + '/index.php/api/productList', data).then((response) => {
							console.log('产品列表', response);
							if(response.code == 200) {
                                let list = response.data;
                                that.edit_list = [];
                                list.forEach((element,index) => {
                                    // console.log(element);
                                    that.edit_list.splice(0,0,{id:element.IDProduct,name:element.chrName,img:element.smallImg,date_time:element.dtCreate,Num:element.NumS});
                                    that.check = val;
                                });
                                that.cNum = response.data.length;
                                console.log(that.edit_list);
                                 // 默认选中
                                setTimeout(() => {
                                    for (let i = 0; i < that.selectProduct.length; i++) {
                                        // $('#edit_id' + that.selectProduct[i].id)[0].innerHTML = $('#edit_id' + that.selectProduct[i].id)[0].innerHTML.replace('class="checkbox"', 'class="checkbox checked"').replace('icon-duigou1">', 'icon-duigou1 checked">')
                                        that.$refs['edit_id' + that.selectProduct[i].id][0].checked = true;
                                    }
                                }, 0);
							}
					})
				}else if(val == 'product_panic'){//编辑当前企业抢购产品
					that.Num_show = true;
					that.cNum = 4;
					that.Title='抢购产品';
					that.$post(that.$path + '/index.php/api/productList', {c_id}).then((response) => {
							console.log('产品列表2', response);
							if(response.code == 200) {
									let list = response.data;
									that.edit_list = [];
									list.forEach((element,index) => {
										// console.log(element);
										that.edit_list.splice(0,0,{id:element.IDProduct,name:element.chrName,img:element.smallImg,date_time:element.dtCreate,Num:element.NumS});
										that.check = val;
									});
									console.log(that.edit_list);
							}
					})
				}else if(val == 'news'){//编辑当前企业新闻咨询
					that.Num_show = false;
					// that.cNum = 4;
                    that.Title='新闻咨询';
                    that.ed_show=true;
                    var data = this.Card;
                    data.c_id = this.CardDetails.c_id;
					that.$post(that.$path + '/index.php/api/newsList', data).then((response) => {
							console.log('新闻列表', response);
							if(response.code == 200) {
                                let list = response.data;
                                that.edit_list = [];
                                list.forEach((element,index) => {
                                    // console.log(element);
                                    that.edit_list.splice(0,0,{id:element.IDNews,name:element.Title,img:element.img[0],date_time:element.dtCreate});
                                    that.check = val;
                                });
                                that.cNum = response.data.length;
                                console.log(that.edit_list);
                                // 默认选中
                                setTimeout(() => {
                                    for (let i = 0; i < that.selectNews.length; i++) {
                                        // $('#edit_id' + that.selectNews[i].id)[0].innerHTML = $('#edit_id' + that.selectNews[i].id)[0].innerHTML.replace('class="checkbox"', 'class="checkbox checked"').replace('icon-duigou1">', 'icon-duigou1 checked">')
                                        that.$refs['edit_id' + that.selectNews[i].id][0].checked = true
                                    }
                                }, 0);
							}
					})
				}else if(val == 'activity'){//编辑当前企业的活动
					that.Num_show = false;
					that.cNum = 4;
					that.Title='活动动态';
					that.$post(that.$path + '/api.php/Activity/getActivityList', {c_id}).then((response) => {
							console.log('活动列表', response);
							if(response.code == 200) {
									let list = response.data;
									that.edit_list = [];
									list.forEach((element,index) => {
										// console.log(element);
										that.edit_list.splice(0,0,{id:element.id,name:element.title,img:element.img,date_time:element.begin_time});
										that.check = val;
									});
									console.log(that.edit_list);
							}
					})
				}else if(val == 'module'){//添加模块
					that.Num_show = false;
					that.cNum = 3;
					let status = 1;
					that.Title='添加模块';
					that.ed_show=false;
					// that.$post(that.$path + '/api.php/Company/getCompnayModuleList', {c_id}).then((response) => {
							// console.log('活动列表', response);
							// if(response.code == 200) {
									// let list = response.data;
									let list = that.addModuleList;
									that.edit_list = [];
									list.forEach((element,index) => {
										// console.log(element);
										that.edit_list.splice(0,0,{id:element.id,name:element.name});
										that.check = val;
									});
									console.log(that.edit_list);
					// 		}
					// })
				}
				this.activeShow = true;
            },
            
			/**
             * 点击选择需要显示的内容
             */
			singChange(){
				let n = 0;
				let ids = '';
				this.edit_list.forEach(el => {
				if(el.checked) {
					n+=1;
					ids += el.id + ',';
				}
					// if(n <3){
					// 	if(el.checked) {
					// 			n+=1;
					// 			ids += el.id + ',';
					// 	}
					// }else{
					// 		el.checked = false;
					// }
					
                })
                // 限制选择3个以上
                var ids_arr = ids.split(',');
                ids_arr.pop();
                console.log(ids_arr)
                this.xNum = n;
                this.ids = ids;
                if(ids_arr.length > 3){
                    this.$openTips({
                        text: '最多选择3个',
                        time: 2000
                    })
                    // 对比出新增了那个id
                    for (let i = 0; i < ids_arr.length; i++) {
                        var reg = new RegExp('(?:^|,)' + ids_arr[i] + ',');
                        if(!this.prev_ids.match(reg)){
                            this.$refs['edit_id' + ids_arr[i]][0].checked = false;
                        }
                    }
                    return false;
                }
                this.prev_ids = ids;
                console.log(ids) 
				// this.xNum = n;
                // this.ids = ids;
                // if(ids.split(',').length > 4){
                //     this.$openTips({
                //         text: '最多选择3个商品',
                //         time: 2000
                //     })
                //     return false;
                // }
				// console.log(ids);
			},


            /**
             * 分享开关
             */
            showFunc: function() {
                if (this.position == '-2.66rem') {
                this.position = '-0.1rem';
                } else {
                this.position = '-2.66rem'
                }
            },
            // 点击右上角下拉
            // gotobtn() {
            //     this.dropintopShow = !this.dropintopShow;
            // },  
            // 点击空白，下拉框收起
            // closeDrown() {
            //     this.dropintopShow = false;
            // },
        },
        components: {
            headerSearch,
            soFooter,
            Checkbox,
            editorHead
        }
    }
</script>

<style>
/* 名片式的模块 */
.look_container {
  width: 7rem;
  margin: 0 auto;
  border-radius: 4px;
}

.main_card_index {
    height: 4.4rem;
}
/* 头部浮层底部的红色部分 */
.main_card_index .main_card_index_info-top {
    height: 2.16rem;
    width: 100%;
    background-color: #e50838;
    position: absolute;
    top: 0;
    left: 0;
}
/* 头部浮层信息 */
.main_card_index .main_card_index_info {
    width: 7rem;
    height: 4.2rem;
    background-color: #fff;
    border-top-left-radius: 20px;
    position: absolute;
    left: 50%;
    margin-left: -3.5rem;
}
.main_card_index_info .main_card_index_info_top_edit img {
    width: 1.2rem;
    height: 1.2rem;
    border-radius: 50%;
    float: left;
    margin: 0.3rem;
    box-sizing: border-box;
}
.main_card_index_info_top_edit .main_card_index_info_center_edit {
    float: left;
    text-align: left;
    width: 55%;
    margin-top: 0.46rem;
    box-sizing: border-box;
}
.main_card_index_info_center_edit h2 {
    font-size: 0.34rem;
    color: #000;
    height: 0.48rem;
    line-height: 0.48rem;
}
.main_card_index_info_center_edit h2 span {
    font-size: 0.28rem;
    color: #333;
    display: inline-block;
    vertical-align: top;
    width: 1rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    -o-text-overflow: ellipsis;
    overflow: hidden;
}
.main_card_index_info_center_edit h2 span:first-child {
    font-size: 0.34rem;
    color: #333;
    width: 2rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    -o-text-overflow: ellipsis;
    overflow: hidden;
    display: inline-block;
}
.main_card_index_info_center_edit p {
    font-size: 0.28rem;
    color: #333;
    white-space: nowrap;
    text-overflow: ellipsis;
    -o-text-overflow: ellipsis;
    overflow: hidden;
    width: 3.4rem;
    height: 0.48rem;
    line-height: 0.48rem;
}
.main_card_index_info_top_edit .main_card_index_info_right {
    float: right;
    margin-top: 0.46rem;
    margin-right: 0.2rem;
    box-sizing: border-box;
    line-height: 0.26rem;
}
.main_card_index_info_top_edit .main_card_index_info_right a{
    font-size: 0.28rem;
    color: #666;
    display: inline-block;
}
.main_card_index_info_top_edit .main_card_index_info_right a .icon-bianji1 {
    margin-right: 0.12rem;
}
.main_card_index_info_top_edit .editor_Card {
    width: 1.2rem;
    height: 1.2rem;
    border-radius: 50%;
    float: left;
    margin: 0.3rem;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}
/* 头部浮层底部 */
.main_card_index_info_bottom {
    border-top: 1px solid #d8d8d8;
    padding: 0.3rem;
    box-sizing: border-box;
}
.main_card_index_info_bottom p {
    font-size: 0.28rem;
    color: #e50838;
    text-align: left;
    line-height: 0.56rem;
    height: 0.56rem;
}
.main_card_index_info_bottom p a {
    font-size: 0.28rem;
    color: #e50838;
}
.main_card_index_info_bottom p .icon-youxiang,
.main_card_index_info_bottom p .icon-dianhua2,
.main_card_index_info_bottom p .icon-dizhi1 {
    width: 0.36rem;
    height: 0.36rem;
    background-color: #e50838;
    font-size: 0.22rem;
    color: #fff;
    border-radius: 50%;
    padding: 0.1rem;
    line-height: 0.36rem;
    box-sizing: border-box;
    text-align: center;
}
.main_card_index_info_bottom p .small_span_color {
    background-color: #e50838;
    padding: 0.08rem;
    border-radius: 2px;
    color: #fff;
    font-size: 0.22rem;
    margin-left: 0.2rem;
    display: inline-block;
    box-sizing: border-box;
    line-height: 0.24rem;
}
.main_card_index_info_bottom p .icon-erweima {
    font-size: 0.4rem;
    color: #999;
}

/* 下拉框 */
.drop_intop_panel {
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  position: fixed;
  top: 0;
  left: 0;
  z-index: 16;
}
.dropDownpanel {
    width: auto;
    height: auto;
    background-color: #fff;
    position: absolute;
    top: 0.88rem;
    right: 0.16rem;
    z-index: 15;
    border-radius: 4px;
    box-shadow: 2px 2px 5px rgba(211, 125, 125, 0.34);
}
.dropDownpanel .dropdown_triangle {
    width: 0;
    height: 0;
    border-right: 8px solid transparent;
    border-left: 8px solid transparent;
    border-bottom: 8px solid #fff;
    position: absolute;
    right: 0.13rem;
    top: -0.14rem;
    z-index: 15;
}
.dropDownpanel a {
    font-size: 0.3rem;
    color: #333;
    display: block;
    line-height: 0.92rem;
    height: 0.92rem;
    text-align: left;
    padding: 0 0.2rem;
}
.dropDownpanel a .icon-icon,
.dropDownpanel a .icon-mobanliebiao,
.dropDownpanel a .icon-fenxiang4,
.dropDownpanel a .icon-genghuanyanse {
    font-size: 0.36rem;
	margin-right: 0.2rem;
	color: #333;
}
.dropDownpanel a .icon-mobanliebiao {
    color: #ff9b01;
}
.dropDownpanel a .icon-genghuanyanse {
    color:#ff4949;
}



/* 访问头条 */
.main_Headline_data {
    width: 7rem;
    background-color: #fff;
    margin: 0 auto;
    padding: 0.1rem 0;
    height: 0.6rem;
    line-height: 0.6rem;
    margin-bottom: 0.2rem;
    position: relative;
}
.main_Headline_data small{
    color: #999;
    font-size: 0.36rem;
    transform: scale(0.56);
    display: block;
    line-height: 0.44rem;
    float: left;
    margin: 0 -0.315rem;
    width: 1.79rem;
}
.main_Headline_data small em {
    color: #e50838;
}
.main_Headline_data .data_jin {
    border: 1px solid #d8d8d8;
    border-radius: 2px;
    padding: 0 0.05rem;
    margin-top: -0.1rem;
    height: 0.6rem;
    line-height: 0.6rem;
    box-sizing: border-box;
    text-align: center;
}
.main_Headline_data .notice_editor {
    position: absolute;
    width: 100%;
    height: 0.6rem;
    background-color: rgb(0,0,0,0.4);
    left: 0;
    top: 0;
}
.notice_editor small {
    float: right;
    height: 0.6rem;
    color: #fff;
}
.notice_editor small a {
    font-size: 0.5rem;
    color: #fff;
    line-height: 0.6rem;
    margin-right: 0.4rem;
}
.notice_editor small a:last-child {
    margin-right: 0;
}
.notice_editor .icon-shanjian {
    position: absolute;
    left: -.1rem;
    top: -0.3rem;
    color: #e50838;
    font-size: 0.3rem;
}
.notice_editor .icon-shanchu,
.notice_editor .icon_editor {
    font-size: 0.5rem;
    color: #fff;
    margin-right: 0.06rem;
}
/* 公司简介 */

.main-company-index-description {
	padding-bottom: 0.2rem;
    background-color: #fff;
}
.main-company-index-description .option_description {
	display: flex;
	justify-content: flex-start;
	padding: 0 0.2rem;
}
.main-company-index-description .option_description .userCard_check_img {
    width: 0.7rem;
    height: 0.7rem;
    display: block;
    vertical-align: middle;
    text-align: center;
    margin: 0;
    padding: 0;
    margin-right: 0.4rem;
}
.main-company-index-description .option_description img{
	width: 0.7rem;
    height: 0.7rem;
    max-width: 100%;
    max-height: 100%;
    vertical-align: super;
}
.main-company-index-description .option_description h3 {
	font-size: 0.34rem;
	color: #333;
	line-height: 0.36rem;
}
.main-company-index-description .option_description p {
	font-size: 0.18rem;
	color: #999;
	padding: 0;
	line-height: 0.46rem;
}
.company_description_info {
    border: 1px dashed #d8d8d8;
    height: auto;
    min-width: 2rem;
    display: inline-block;
    line-height: 0.44rem;	
}
.company_description_span {
    border: 1px dashed #d8d8d8;
    height: auto;
    line-height: 0.48rem;
}

.main-company-index-description p {
    font-size: 0.26rem;
    color: #333;
    text-align: left;
    padding: 0.2rem;
}
.option_tagNames {
    margin: 0;
    padding: 0 .2rem;
    box-sizing: border-box;
    overflow: hidden;
    margin-top: 0.1rem;
}
.option_tagNames span {
    font-size: .22rem;
    background-color: #999;
    color: #fff;
    float: left;
    margin-right: .1rem;
    box-sizing: border-box;
    margin-bottom: 0.1rem;
    display: inline-block;
    text-align: center;
    line-height: 0.46rem;
}
/* 查看更多企业信息 */ 
.btn_more {
    font-size: 0.26rem;
    color: #e50838 !important;
    display: block;
    padding-bottom: 0.2rem;
    background-color: #fff;
    margin-top: -0.2rem;
    padding-top: 0.2rem;
}
/* 企业商品 */
.main-company-index_product {
	background-color: #fff;
	margin-top: 0.2rem;
}
.main-company-index_product .hui_title {
    width: 2.2rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    -o-text-overflow: ellipsis;
    overflow: hidden;
}

#js_host_item {
  padding: 0.12rem;
}
#js_host_item ul>li {
  margin-right: 0;
}
#js_host_item img {
    width: 100%;
    max-width: 2rem;
    height: 2rem;
    max-height: 2rem;
}
/* 产品为空 */
#js_host_item .emptyProduct {
  padding: 0 0 0.2rem;
  box-sizing: border-box;
}
#js_host_item .emptyProduct img {
  width: 1.56rem;
  height: 1.22rem;
  margin: 0 auto;
}
#js_host_item .emptyProduct p {
  font-size: 0.26rem;
  color: #999;
  text-align: center;
}


/* 新闻动态 */
.info_list_home_page ul>li {
    position: relative;
    border-bottom: 1px solid #d8d8d8;
    padding: 0.2rem;
    box-sizing: border-box;
}
.info_list_home_page ul>li .new_info_single_img {
  width: 1.2rem;
  height: 1.2rem;
  margin-right: 0.2rem;
  text-align: center;
  vertical-align: middle;
}
.info_list_home_page ul>li .new_info_single_img img {
  width: 1.2rem;
  height: 1.2rem;
  max-width: 100%;
  max-height: 100%;
}
/* .info_list_home_page ul>li:last-child {
    border-bottom: none;
} */
/* .info_list_home_page ul>li img {
    width: 100%;
    max-width: 1.2rem;
    display: inline-block;
    height: 1.2rem;
    max-height: 1.2rem;
    float: left;
    margin-right: 0.2rem;
} */
.info_list_home_page ul>li p {
    font-size: .28rem;
    color: #333;
    text-align: left;
}
.info_list_home_page ul>li p:last-child {
    font-size: .22rem;
    color: #999;
    display: flex;
    justify-content: space-between;
    position: absolute;
    width: 75%;
    bottom: 0.2rem;
    right: 0.2rem;
}

/* 新闻为空 */
.info_list_home_page .emptyProduct {
  padding: 0 0 0.2rem;
  box-sizing: border-box;
}
.info_list_home_page .emptyProduct img {
  width: 1.56rem;
  height: 1.22rem;
  margin: 0 auto;
}
.info_list_home_page .emptyProduct p {
  font-size: 0.26rem;
  color: #999;
  text-align: center;
}


/* 多图新闻 */
.info_home_page p {
    font-size: .28rem;
    color: #333;
    text-align: left;
    margin-bottom: 0.2rem;
}
.info_home_page ul {
    display: flex;
    justify-content: flex-start;
    margin-bottom: 0.3rem;
}
.info_home_page ul>li {
    margin-right: 0.16rem;
    padding: 0 !important;
}
.info_home_page ul>li .new_info_img {
  width: 2.24rem;
  height: 1.46rem;
  margin-right: 0.19rem;
  text-align: center;
  vertical-align: middle;
}
.info_home_page ul>li li:last-child .new_info_img {
  margin-right: 0;
}
.info_home_page ul>li .new_info_img img {
  width: 2.24rem;
  height: 1.46rem;
  max-width: 100%;
  max-height: 100%;
}
.info_home_page ul>li .info_home_img {
    width: 2.04rem;
    height: 1.2rem;
    float: left;
    display: inline-block;
    margin-right: 0.1rem;
}

/* 多图新闻 */
.info_home_page .info_time {
    width: 100% !important;
    position: absolute !important;
    right: 0 !important;
    left: 0;
    margin-bottom: -0.2rem;
    line-height: 0.4rem;
    padding: 0 0.2rem;
} 

/* 分享按钮 */
.view_card_share {
    position: fixed;
    height: 2rem;
    width: 3rem;
    font-size: 0.26rem;
    display: flex;
    top: 50%;
    margin-top: -1.5rem;
}
.view_card_share .share_hide_btn {
    width: .8rem;
    height: .6rem;
    border-radius: 50% 0 0 50%;
    border-left: 1px solid #999;
    text-align: left;
    background-color: #fff;
    line-height: 0.6rem;
    top: 54%;
    position: absolute;
    z-index: 100;
    color: #e50838;
}
.share_hide_collection {
    margin-left: .6rem;
    color: #333;
    position: absolute;
    top: 20% !important;
    z-index: 100;
}
.share_hide_collection .hide_collection {
    margin: .08rem 0;
    border: 1px solid #ccc;
    background-color: #fff;
    line-height: .3rem;
    border-radius: .28rem;
    padding: 0.1rem 0.4rem;
}
.share_hide_collection .hide_collection .icon-shoucang {
  color: #e50838;
  margin-right: 0.12rem;
}
.share_hide_collection .hide_collection .icon-fenxiang2 {
  color: #FF9938;
  margin-right: 0.12rem;
}


/* 添加模块 */
.mycard_insert {
    height: 1.5rem;
    width: 7rem;
    border: 1px dashed #d8d8d8;
    text-align: center;
    margin: 0 auto;
    margin: 0.4rem auto;
}
.mycard_insert .icon-icon02 {
    font-size: 0.48rem;
}
.mycard_insert span {
    font-size: 0.4rem;
    color: #999;
}

/* 编辑动态弹框 */
.Editorial_dynamics .intop {
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.5);
	position: fixed;
	top: 0;
	left: 0;
	z-index: 20;
}
.Editorial_dynamics .editorial_list {
	background-color: #fff;
	border-radius: 4px;
	width: 7rem;
	height: 6.7rem;
	overflow: hidden;
	position: absolute;
	z-index: 20;
	left: 50%;
	margin-left: -3.5rem;
	top: 50%;
	margin-top: -3.35rem;
}
.editorial_list .editorial_title {
	display: flex;
	justify-content: space-between;
	font-size: 0.28rem;
	color: #333;
	border-bottom: 1px solid #d8d8d8;
	line-height: 0.46rem;
	margin-top: 0.12rem;
	padding-bottom: 0.12rem;
}
.editorial_title button {
	border: 0;
	background-color: transparent;
	color: #999;
	font-size: 0.28rem;
	margin: 0 0.2rem;
}
.editorial_title button:last-child {
	background-color: #e50838;
	color: #fff;
	width: 1.14rem;
	border-radius: 4px;
}
.editorial_title h3 {
	font-weight: normal;
}
.editorial_list .editorial_excl {

}
.editorial_excl .editorial_item {
	padding: 0.2rem;
	border-bottom: 1px solid #d8d8d8;
}
.editorial_item img {
	width: 1rem;
	height: 1rem;
}
.editorial_item .editorial_item_title {
		line-height: 0.38rem;
    margin: 0.12rem;
		margin-left: 0.2rem;
}
.editorial_item .editorial_item_title p {
	font-size: 0.28rem;
	color: #333;
	text-align: left;
	display: block;
	width: 4.6rem;
}
.editorial_item .editorial_item_title p:first-child {
	width: 2rem;
	white-space: nowrap;
	text-overflow: ellipsis;
	-o-text-overflow: ellipsis;
	overflow: hidden;
}
.editorial_item .editorial_item_title p em {
	font-style: normal;
	color: #e50838;
}
.editorial_item .editorial_change {
	position: absolute;
    width: 100%;
    right: 0;
    text-align: right;
    top: 0rem;
    padding-right: 0.3rem;
}
.addModuleList {
  
    position: fixed;
  
    width: 100%;
  
    height: 100%;
  
    background-color: rgba(0, 0, 0, 0.4);
  
    z-index: 99999;
  
  }
  .addModuleList>ul {
  
    /* background-color: #fff; */
  
    position: absolute;
  
    bottom: 0;
  
    width: 100%;
  
  }
  .addModuleList li {
  
    border: 1px solid #ccc;
  
    background-color: #fff;
  
    color: #6699ff;
  
    font-size: 0.28rem;
  
    height: 0.75rem;
  
    line-height: 0.75rem;
  
    border-radius: 0.08rem;
  
    margin: -0.05rem 0.1rem;
  
  }
  .addModuleList li:last-child {
  
    margin: 0.3rem 0.1rem 0 0.1rem;
  
  }


</style>